import java.util.Scanner;

/*
 *Description:
 *User:laoHu
 *Created with Intellij IDEA 2025
 *Data:2025.05.00
 *Time:00:00
 */
//TIP To <b>Run</b> code, press <shortcut actionId="Run"/> or
// click the <icon src="AllIcons.Actions.Execute"/> icon in the gutter.
public class Main {
    public static String solve (String str1, String str2) {

        //  1 1 0 0
        //  1 1 1 1
        //  1  0  1   1
        int len1 = str1.length()-1;
        int len2 = str2.length()-1;
        char[] ch;
        if(len2 > len1) {
            ch = new char[len2 + 2];
        }else{
            ch = new char[len1 + 2];
        }
        for (int i = 0; i < ch.length; i++) {
            ch[i] = '0';
        }
        int pos = 0;
        while (len1 >= 0 && len2 >= 0) {
            if(str1.charAt(len1) == str2.charAt(len2)){
                //1 + 1
                if(str1.charAt(len1) == '1'){
                    ch[pos +1] = '1';
                    //0 + 0
                }else{
                    if(ch[pos] == '1') {
                        ch[pos] = '1';
                    }
                }
                // 0 + 1
            }else{
                if(ch[pos] == '1'){
                    ch[pos + 1] = '1';
                    ch[pos] = '0';
                }
                else ch[pos] = '1';
            }
            pos++;len2--;len1--;
        }
        if(len2 == -1 && len1 >=0) {
            for (int i = len1; i >= 0; i--) {
                if(ch[pos] == '1' && str1.charAt(i) == '1'){
                    ch[pos + 1] = '1';
                    ch[pos] = '0';
                }else if(ch[pos] == '0' && str1.charAt(i) == '1'){
                    ch[pos] = '1';
                }
                pos++;
            }
        }else if(len1 == -1 && len2 >=0){
            for (int i = len2; i >= 0; i--) {
                if(ch[pos] == '1' && str2.charAt(i) == '1'){
                    ch[pos + 1] = '1';
                    ch[pos] = '0';
                }else if(ch[pos] == '0' && str2.charAt(i) == '1'){
                    ch[pos] = '1';
                }
                pos++;
            }
        }
        if(ch[ch.length -1] == '1') {
            int left = 0;
            int right = ch.length -1;
            while(left < right){
                char c = ch[left];
                ch[left] = ch[right];
                ch[right] = c;
                left++;
                right--;
            }
            return String.valueOf(ch);
        }else{
            int left = 0;
            int right = ch.length - 2;
            while(left < right){
                char c = ch[left];
                ch[left] = ch[right];
                ch[right] = c;
                left++;
                right--;
            }
            char[] tem = new char[ch.length - 1];
            for(int i = 0;i<tem.length;i++){
                tem[i] = ch[i];
            }
            return String.valueOf(tem);
        }
    }

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while(scanner.hasNext()){
            String s1 = scanner.next();
            String s2 = scanner.next();

            System.out.println(solve(s1,s2));
        }
    }

    public static void main2(String[] args) {
        Scanner in = new Scanner(System.in);
        while(in.hasNext()){
            String s = in.nextLine();
            char ch = s.charAt(0);
            if(ch >='A' || ch <= 'Z')
            {
                ch = (char)(ch + 32);
            }
            System.out.println(ch);
        }
    }
    public static void cover(char[] tem,int pos){
        int len = tem.length;
        for(int i = pos;i < len - 1;i++){
            tem[i] = tem[i+1];
        }
    }
    public static void main1(String[] args) {
        Scanner in = new Scanner(System.in);
        String s1 = in.nextLine();
        String s2 = in.nextLine();

        char[] tem = new char[s1.length()];
        for (int i = 0; i < tem.length; i++) {
            tem[i] = s1.charAt(i);
        }
        int cnt = 0;
        for(int j = 0;j < s2.length();j++){
            for(int i = 0;i < tem.length;i++){
                if(tem[i] == s2.charAt(j)){
                    cover(tem,i);
                    i--;
                    cnt++;
                }
            }
        }
        char[] tem1 = new char[tem.length - cnt];
        for(int i = 0;i < tem.length - cnt;i++){
            tem1[i] = tem[i];
        }
        System.out.print(String.valueOf(tem1));
    }
}